home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
CU Amiga Super CD-ROM 11
/
CU Amiga Magazine's Super CD-ROM 11 (1997)(EMAP Images)(GB)(Track 1 of 3)[!][issue 1997-06].iso
/
s
/
nocaps.pprx
< prev
next >
Wrap
Text File
|
1992-03-14
|
1KB
|
55 lines
/*
@BNoCaps @P@ICopyright Gold Disk Inc., February, 1992
This Genie will change all letters in a block of text to lower case.
*/
if ~show(l, "gdarexxsupport.library") then
if ~(exists("libs:gdarexxsupport.library") & addlib("gdarexxsupport.library", 0, -30)) then
exit_msg("Please install the gdarexxsupport.library in your libs: directory before running this Genie")
if word(ppm_GetState(), 1) ~= "3" then
exit_msg("This Genie works only in edit mode!!")
text = ppm_GetBlockText(1)
if text = '' then exit_msg("No block selected")
i = 1
len = length(text)
lrange = xrange('a', 'z')
urange = xrange('A', 'Z')
call ppm_ShowStatus("Working...")
do while i < len
curletter = substr(text, i, 1)
do while curletter= '\'
i = skipcodes(text, i)
curletter = substr(text, i, 1)
end
if curletter = ' ' then
do
i = i + 1
iterate
end
curletter = translate(curletter, lrange, urange)
text = overlay(curletter, text, i)
i = i + 1
end
call ppm_InsertText(text)
call ppm_ClearStatus()
exit
exit_msg:
do
parse arg msg
call ppm_ShowStatus(msg)
exit
end